﻿@model EShop.Models.Goods

@{
    ViewBag.Title = "Create";
}

<h2>新建</h2>

@using (Html.BeginForm()) {
    @Html.AntiForgeryToken()
    @Html.ValidationSummary(true)

    <fieldset>
        <legend>Goods</legend>

        <div class="editor-label">
            @Html.LabelFor(model => model.GenreId, "分类")
        </div>
        <div class="editor-field">
            @Html.DropDownList("GenreId", String.Empty)
            @Html.ValidationMessageFor(model => model.GenreId)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.brandId, "描述")
        </div>
        <div class="editor-field">
            @Html.DropDownList("brandId", String.Empty)
            @Html.ValidationMessageFor(model => model.brandId)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Name, "名称")
           
            )
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Name)
            @Html.ValidationMessageFor(model => model.Name)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Price, "价格")
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Price)
            @Html.ValidationMessageFor(model => model.Price)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.GoodsUrl, "图片地址")
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.GoodsUrl)
            @Html.ValidationMessageFor(model => model.GoodsUrl)
        </div>

        <p>
            <input type="submit" value="新建" />
        </p>
    </fieldset>
}

<div>
    @Html.ActionLink("返回列表", "Index")
</div>

@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
}
